#ifndef BASEFRAMEMOVE_H
#define BASEFRAMEMOVE_H

#include <QObject>
#include <QWidget>
#include <QMouseEvent>
#include <QPoint>


class baseFrameMove : public QWidget
{
    Q_OBJECT
public:
    baseFrameMove(QWidget *parent = nullptr);
    ~baseFrameMove(){};

    //事件过滤器
    bool eventFilter(QObject *, QEvent *) override;

/*
//重写鼠标事件
protected:
    void mousePressEvent(QMouseEvent *) override;
    void mouseReleaseEvent(QMouseEvent *)override;
    //void mouseDoubleClickEvent(QMouseEvent *)override;
    void mouseMoveEvent(QMouseEvent *)override;
*/

private:
    bool m_isPressed;  //是否按下的标志
    QPoint m_point;    //记录鼠标按下的位置
    QRect m_moveable;

};

#endif // BASEFRAMEMOVE_H
